home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Loadstar 168
/
168.d81
/
mars data
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-08-26
|
5KB
|
205 lines
5 poke55,.:poke56,56:clr
6 dv=peek(186):ifdv<8thendv=8
7 print"[147]":poke53280,.:poke53281,.
10 poke53371,.
14 poke53272,31
16 ad=49152
17 sysad:sysad+12
19 print"[147]"
47 bs$="[154][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164][157][164]"
50 dt=57
55 p2=2*(NULL):rd=180/(NULL):dr=1/rd
60 gosub385
65 d=(j-2451545)+f
70 d=d+dt/86400
72 gosub490
75 poke214,10:print:printtab(1)"[156][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162]"
77 sysad+9,12
80 read a1,a2,d1,d2
85 t=t-1
90 a1=a1+a2*t
95 d1=d1+d2*t
100 q=a1:gosub825:a1=q*dr
105 q=d1:gosub825:d1=q*dr
110 d9=cos(d5)*sin(a1-a5)
115 n9=sin(d1)*cos(d5)*cos(a1-a5)
120 n9=n9-cos(d1)*sin(d5)
125 k=rd*atn(n9/d9)
130 ifd9<0thenk=k+180
135 readw0,w1,w2:gosub330
140 rem planetoecentic declination earth
145 sd=-sin(d1)*sin(d5)
150 sd=sd-cos(d1)*cos(d5)*cos(a1-a5)
155 de=rd*atn(sd/sqr(1-sd*sd))
160 rem p.a. of axis
165 sp=cos(d1)*sin(a1-a5)
170 cp=sin(d1)*cos(d5)
175 cp=cp-cos(d1)*sin(d5)*cos(a1-a5)
180 pa=rd*atn(sp/cp)
185 ifcp<0thenpa=pa+180
190 ifpa<0thenpa=pa+360
195 ifpa>=360thenpa=pa-360
200 rem phase and magnitude
205 k4=((r4+rr)^2-r*r)/(4*r4*rr)
210 ci=(r4*r4+rr*rr-r*r)/(2*r4*rr)
215 i=rd*atn(sqr(1-ci*ci)/ci)
220 m4=5*log(rr*r4)/log(10)
225 m4=-1.52+.016*i+m4
230 a1$="[153][195]entral [205]eridian:[158]"
235 a2$="[153][208].[193]. of [193]xis:[158]"
240 a3$="[153][196]eclin. of [197]arth:[158]"
245 a4$="[153][193]ngular [211]ize (arcsec):[158]"
250 a5$="[153]% [211]urface lit:[158]"
255 a6$="[153][205]agnitude:[158]"
260 printtab(4)a1$;c;"[219]":gosub900
265 printtab(4)a2$;pa;"[219]"
270 printtab(4)a3$;de;"[219]"
275 printtab(4)a4$;9.36/rr
280 printtab(4)a5$;k4*100
285 printtab(4)a6$;m4
290 gosub4000
300 restore:goto47
330 rem rotations from epoch
335 w=w0+w1*(d-.0057755*rr)+w2*t
340 q=w-k:gosub825:c=q
345 return
350 rem north pole r.a.
355 data317.681,+0.678
360 rem north pole declin.
365 data52.886,+0.352
370 rem rotation
375 data176.655,350.8919830,0.62
380 rem calendar -->jd
385 print"[147]":sysad+9,3
386 print"[154][220][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][221]"
387 printbs$""tab(38)bs$
388 print"[154][255][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][161]"
390 print""tab(8)"[150][205] [193] [210] [212] [201] [193] [206] [196] [193] [212] [193]"
395 print:printtab(6)"[158][197]nter [217]ear: ";:l9%=4:gosub840:y=q9
400 printtab(6)"[158][205]onth: ";:l9%=2:gosub840:m=q9
402 ifm=<0orm>12thenprint"[145][145]":goto400
405 printtab(6)"[158][196]ay: ";:l9%=2:gosub840:d=q9
407 ifd=<0ord>31thenprint"[145][145]":goto405
410 print:printtab(6)"[158][213]niversial [212]ime-[200]our: ";:l9%=2:gosub840:h1=q9
412 ifh1<0orh1>24thenprint"[145][145]":goto410
415 printtab(6)"[158][205]inutes: ";:l9%=2:gosub840:m1=q9
416 ifm1<0orm1>60thenprint"[145][145]":goto415
418 printtab(6)"[158][211]econds: ";:l9%=2:gosub840:s1=q9
419 ifs1<0ands1>60thenprint"[145][145]":goto418
421 poke214,10:print:printtab(6)"[155][201]s this correct? [150][217]/[206]":poke198,.
422 gosub930
424 sysad+9,5
425 d=d+h1/24+m1/1440+s1/86400
430 g=1:ify<1582theng=0
435 d1=int(d):f=d-d1-.5
440 j=-int(7*(int((m+9)/12)+y)/4)
445 ifg=0then465
450 s=sgn(m-9):a=abs(m-9)
455 j3=int(y+s*int(a/7))
460 j3=-int((int(j3/100)+1)*3/4)
465 j=j+int(275*m/9)+d1+g*j3
470 j=j+1721027+2*g+367*y
475 iff>=0then485
480 f=f+1:j=j-1
485 return
490 rem fundamental arguments
495 t=d/36525+1
500 rem t=centuries from 1900.0
505 l0=.779072+.00273790931*d
510 g0=.993126+.0027377785*d
515 l4=.987353+.00145575328*d
520 g4=.053856+.00145561327*d
525 f4=.849694+.00145569465*d
530 l5=.089608+.00023080893*d
535 g5=.056531+.00023080893*d
540 g6=.882987+9.294371e-05*d
545 l0=(l0-int(l0))*p2
550 g0=(g0-int(g0))*p2
555 l4=(l4-int(l4))*p2
560 g4=(g4-int(g4))*p2
565 f4=(f4-int(f4))*p2
570 l5=(l5-int(l5))*p2
575 g5=(g5-int(g5))*p2
580 g6=(g6-int(g6))*p2
585 rem sun
590 l=6910*sin(g0)
595 l=l+72*sin(2*g0)
600 l=l-17*t*sin(g0)
605 l=l-7*cos(g0-g5)
610 r=1.00014-.01675*cos(g0)
615 r=r-.00014*cos(2*g0)
620 l=l0+l/206265
625 rem mars
630 m=38451*sin(g4)
635 m=m+2238*sin(2*g4)
640 m=m+181*sin(3*g4)
645 m=m-52*sin(2*f4)
650 m=m+37*t*sin(g4)
655 m=m-22*cos(g4-2*g5)
660 m=m-19*sin(g4-g5)
665 m=m+17*cos(g4-g5)
670 m=m+17*sin(4*g4)
675 m=m-16*cos(2*g4-2*g5)
680 m=m+13*cos(g0-2*g4)
685 m=m-10*sin(g4-2*f4)
690 m=m+7*cos(g0-g4)
695 m=m-7*cos(2*g0-3*g4)
700 b=6603*sin(f4)
705 b=b+622*sin(g4-f4)
710 b=b+615*sin(g4+f4)
715 b=b+64*sin(2*g4+f4)
720 r4=1.53031-.1417*cos(g4)
725 r4=r4-.0066*cos(2*g4)
730 r4=r4-.00047*cos(3*g4)
735 l4=l4+m/206265:b4=b/206265
740 n9=r4*cos(b4)*sin(l4-l)
745 d9=r4*cos(b4)*cos(l4-l)+r
750 l1=atn(n9/d9)
755 ifd9<0thenl1=l1+(NULL)
760 ll=l1+l
765 v=n9*n9+d9*d9
770 rr=sqr(v+(r4*sin(b4))^2)
775 s=r4*sin(b4)/rr
780 bb=atn(s/sqr(1-s*s))
785 e=(84428-47*t)/206265
790 n9=sin(ll)*cos(e)-tan(bb)*sin(e)
795 d9=cos(ll):a5=atn(n9/d9)
800 ifd9<0thena5=a5+(NULL)
805 s=sin(bb)*cos(e)
810 s=s+cos(bb)*sin(e)*sin(ll)
815 d5=atn(s/sqr(1-s*s))
820 return
825 rem normalize degrees
830 q=q/360:q=q-int(q):q=q*360
835 return
840 q9$="":poke198,.
842 geta$
844 poke646,rnd(1)*15+1:print"*[157]";:ifa$=""then842
846 ifa$=chr$(13)thenprint" ":q9=val(q9$):return
848 if(a$=chr$(20)andlen(q9$))thenq9$=left$(q9$,len(q9$)-1):goto860
850 iflen(q9$)>=l9%thensysad+9,15:goto842
852 if(a$>="0"anda$<="9")ora$="."ora$="-"then856
854 goto842
856 q9$=q9$+a$
858 print""a$;:sysad+9,6:goto842
860 print" [157][157] [157]";:goto842
900 ifc>=0andc<60thenprinttab(3)"[150][197]rythraeum [205]are, [214]iking 1 area!":return
905 ifc>=60andc<120thenprinttab(3)"[150][211]olis [204]acus, and [212]harsis region":return
910 ifc>=120andc<180thenprinttab(3)"[150][211]irenum [205]are and [207]lympus mons!":return
915 ifc>=180andc<240thenprinttab(3)"[150][195]immerium [205]are & [200]esperia area":return
920 ifc>=240andc<300thenprinttab(3)"[150][211]yrtis [205]ajor and [214]iking 2 area":return
925 ifc>=300andc<360thenprinttab(3)"[150][211]epentis [205]are, [211]inus [205]eridiani":return
930 gethc$:ifhc$<>"y"andhc$<>"n"then930
935 ifhc$="y"thenreturn
940 ifhc$="n"then385
4000 poke214,20:print:printtab(8)"[159](1[159]) [212]ry another one
4005 [153][163]8)"open(2open) (NULL)o (NULL)(NULL)right$(NULL)val(NULL)(NULL)val (NULL)enu"
4010 [158]ad[170]9,5:[151]198,0
4015 [161]a$:[139]a$[179]"1"[176]a$[177]"2"[167]4015
4020 [139]a$[178]"1"[167][142]
4025 [158]ad[170]15
4030 [153]"loadstopload"[199](34)"b.universe ii"[199](34)","dv
4035 [153]"run28"
4040 [151]631,13:[151]632,13:[151]198,2:[128]
10000 d[178][194](186):n$[178]"mars data":[159]15,d,15,"s0:"[170]n$:[160]15:[148]n$,d:[128]